﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BaseCoder.ModelCoder;
using BaseCoder.DALCoder;
using System.Configuration;
using BaseCoder.BLLCoder;
using BaseCoder.IDALCoder;
using System.IO;

namespace BaseCoder
{
    class Program
    {
        static void Main(string[] args)
        {
            string currentProject = ConfigurationManager.AppSettings["Project"];
            ProjectConfig config = new ProjectConfig(currentProject);
            string ConnectionString = config.ConectionString;

            //ModelCreate modelCreate = new ModelCreate(config);
            //modelCreate.CreateModel();
            DALCreate dalCreate = new DALCreate(config);
            dalCreate.CreateDAL();
            //BLLCreate bllCreate = new BLLCreate(config);
            //bllCreate.CreateBLL();

            if (config["IsFactory"] == "1")
            {
                IDALCreate idalCreate = new IDALCreate(config);
                idalCreate.CreateIDAL(ConnectionString);
            }
            Console.WriteLine("按任意键退出...");

        }
    }
}
